const { default: axios } = require('axios');

const router = require('express').Router()

/**
 * @api {get} /information 获取资讯数据
 * @apiName 获取资讯数据
 * @apiGroup information(资讯相关)
 * @apiDescription 获取资讯数据
 * @apiVersion  1.0.0
 * @apiParam {String} informationId=''  资讯Id
 * 
 * @apiParamExample  {type} 请求示例:
 * {  
 *    informationId:10086,
 * }
 * 
 * @apiSuccess {Number} code 200
 * @apiSuccess {Object} datas 数据信息
 * @apiSuccessExample {type} 返回示例:
 * {
     code:200
     data: {
            informations: [{
                    "id": 1,
                    "images": "111111111",
                    "title":"《葫芦娃救爷爷》  七娃被吃掉了",
                    "introduction":"本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
                    "type":"冒险/动画",
                    "actor":"大娃,二娃,三娃,爷爷,蛇精"
                }],
     msg: "ok"
  },
}
 * 
 */
router.get('/information', (req, res) => {
    let { informationId } = req.query
    console.log(informationId);
    let mockinformation = [
        {
            "id": 1,
            "images": "https://sz2115api.zf-maple.cn/images/i_01.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 2,
            "images": "https://sz2115api.zf-maple.cn/images/i_02.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 3,
            "images": "https://sz2115api.zf-maple.cn/images/i_03.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 4,
            "images": "https://sz2115api.zf-maple.cn/images/i_04.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 5,
            "images": "https://sz2115api.zf-maple.cn/images/i_05.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 6,
            "images": "https://sz2115api.zf-maple.cn/images/i_06.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 7,
            "images": "https://sz2115api.zf-maple.cn/images/i_07.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 8,
            "images": "https://sz2115api.zf-maple.cn/images/i_08.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 9,
            "images": "https://sz2115api.zf-maple.cn/images/i_09.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
        {
            "id": 10,
            "images": "https://sz2115api.zf-maple.cn/images/i_10.jpg",
            "title": "《葫芦娃救爷爷》  七娃被吃掉了",
            "introduction": "本片讲述葫芦娃救爷爷,然后被蛇精吃掉了的故事",
            "type": "冒险/动画",
            "actor": "大娃,二娃,三娃,爷爷,蛇精"
        },
    ]
    let mockinformation2 = [
        {
            "id": 11,
            "images": "https://sz2115api.zf-maple.cn/images/i_11.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 12,
            "images": "https://sz2115api.zf-maple.cn/images/i_12.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 13,
            "images": "https://sz2115api.zf-maple.cn/images/i_13.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 14,
            "images": "https://sz2115api.zf-maple.cn/images/i_14.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 15,
            "images": "https://sz2115api.zf-maple.cn/images/i_15.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 16,
            "images": "https://sz2115api.zf-maple.cn/images/i_16.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 17,
            "images": "https://sz2115api.zf-maple.cn/images/i_17.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 18,
            "images": "https://sz2115api.zf-maple.cn/images/i_18.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 19,
            "images": "https://sz2115api.zf-maple.cn/images/i_19.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
        {
            "id": 20,
            "images": "https://sz2115api.zf-maple.cn/images/i_20.jpg",
            "title": "《哪吒闹海》  龙太子被哪吒抽筋了！",
            "introduction": "牛啊！牛啊！哪吒牛牛牛，大闹东海，扒皮抽筋，回家他爹李靖打死他",
            "type": "冒险/动画",
            "actor": "哪吒,龙太子,李静,东海龙王"
        },
    ]
    let mockinformation3 = [
        {
            "id": 21,
            "images": "https://sz2115api.zf-maple.cn/images/i_21.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 22,
            "images": "https://sz2115api.zf-maple.cn/images/i_22.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 23,
            "images": "https://sz2115api.zf-maple.cn/images/i_23.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 24,
            "images": "https://sz2115api.zf-maple.cn/images/i_24.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 25,
            "images": "https://sz2115api.zf-maple.cn/images/i_25.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 26,
            "images": "https://sz2115api.zf-maple.cn/images/i_26.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 27,
            "images": "https://sz2115api.zf-maple.cn/images/i_27.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 28,
            "images": "https://sz2115api.zf-maple.cn/images/i_28.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 29,
            "images": "https://sz2115api.zf-maple.cn/images/i_29.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
        {
            "id": 30,
            "images": "https://sz2115api.zf-maple.cn/images/i_30.jpg",
            "title": "《猴哥三打白骨精》  不好了，臭猴子把小白妹妹打死了！",
            "introduction": "猴子莫得感情，哎！！！！！",
            "type": "冒险/动画",
            "actor": "猴子,白骨精,唐僧"
        },
    ]
    let mockinformation4 = [
        {
            "id": 31,
            "images": "https://sz2115api.zf-maple.cn/images/i_31.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 32,
            "images": "https://sz2115api.zf-maple.cn/images/i_32.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 33,
            "images": "https://sz2115api.zf-maple.cn/images/i_33.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 34,
            "images": "https://sz2115api.zf-maple.cn/images/i_34.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 35,
            "images": "https://sz2115api.zf-maple.cn/images/i_35.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 36,
            "images": "https://sz2115api.zf-maple.cn/images/i_36.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 37,
            "images": "https://sz2115api.zf-maple.cn/images/i_37.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 38,
            "images": "https://sz2115api.zf-maple.cn/images/i_38.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 39,
            "images": "https://sz2115api.zf-maple.cn/images/i_39.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
        {
            "id": 40,
            "images": "https://sz2115api.zf-maple.cn/images/i_40.jpg",
            "title": "《唐哥哥心动女儿国》  轻轻问圣僧，女儿美不美~~~~！",
            "introduction": "女儿国国王：玉帝哥哥嫁给我吗？ 唐僧：嫁！ 白龙马：驾？好嘞，der~",
            "type": "冒险/动画",
            "actor": "女儿国国王,唐僧,白龙马"
        },
    ]
    let mockinformation5 = [
        {
            "id": 41,
            "images": "https://sz2115api.zf-maple.cn/images/i_41.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 42,
            "images": "https://sz2115api.zf-maple.cn/images/i_42.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 43,
            "images": "https://sz2115api.zf-maple.cn/images/i_43.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 44,
            "images": "https://sz2115api.zf-maple.cn/images/i_44.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 45,
            "images": "https://sz2115api.zf-maple.cn/images/i_45.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 46,
            "images": "https://sz2115api.zf-maple.cn/images/i_46.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 47,
            "images": "https://sz2115api.zf-maple.cn/images/i_47.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 48,
            "images": "https://sz2115api.zf-maple.cn/images/i_48.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 49,
            "images": "https://sz2115api.zf-maple.cn/images/i_49.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
        {
            "id": 50,
            "images": "https://sz2115api.zf-maple.cn/images/i_50.jpg",
            "title": "《奥特曼之消逝的光》  孩子，你还相信光吗！",
            "introduction": "世界上是不存在奥特曼的，但你相信光吗？？？",
            "type": "冒险/动画",
            "actor": "迪迦,泰罗,雷欧"
        },
    ]
    let result = mockinformation
    let result2 = mockinformation2
    let result3 = mockinformation3
    let result4 = mockinformation4
    let result5 = mockinformation5




    if(informationId==0){
        res.send({code:200,informations:result,msg:'ok'})
        return
    }
    if(informationId==1000){
        res.send({code:200,informations:result2,msg:'ok'})
        return
    }
    if(informationId==1001){
        res.send({code:200,informations:result3,msg:'ok'})
        return
    }
    if(informationId==1002){
        res.send({code:200,informations:result4,msg:'ok'})
        return
    }
    if(informationId==1003){
        res.send({code:200,informations:result5,msg:'ok'})
        return
    }
})


module.exports = router